UX Advanced PropertiesTemporarily lock event handlers to prevent duplicate events

Description

When enabled, prevents abstract events, such as the click event, from being triggered multiple times within a specified time frame.

Discussion

Rapidly clicking a control can have unintended consequences, such as submitting a new record twice, or emailing the same report multiple times. Event handlers for abstract events (i.e. the Javascript - (Touch, Mouse, Pointer Events) events) are often designed to run to completion before being executed again. While wait messages and lock screens may be used to prevent the user from interacting with the app until the task completes, the user may still be able to trigger the event multiple times before any message can be shown if they double-click the control.

To prevent users from unintentionally firing abstract events multiple times, you can temporarily lock the control after the first click by enabling the Temporarily lock event handlers to prevent duplicate events property. The Temporarily lock event handlers to prevent duplicate events property locks an abstract event handler for a short period of time the first time it's triggered. Subsequent executions of the abstract event within the lock period are ignored.

You can configure how long to lock abstract events using the Lock duration (ms) property. By default, events are locked for 300 milliseconds.

The Temporarily lock event handlers to prevent duplicate events property is enabled by default in all existing and new UX components.

See Also